package com.naodong.shenluntiku.mvp.contract;

import com.naodong.shenluntiku.mvp.model.bean.PagingBean;
import com.naodong.shenluntiku.mvp.model.bean.Study;

import java.util.List;

import io.reactivex.Observable;
import me.shingohu.man.intergation.retrofit.NoBodyEntity;
import me.shingohu.man.mvp.IModel;
import me.shingohu.man.mvp.IView;

/**
 * Created by Administrator on 2017/5/30.
 */

public interface StudyContract {
    interface View extends IView {
        void setStudyListData(boolean isRefresh, PagingBean<List<Study>> listPagingBean);

        void onReadSuccess(int rcId);
    }

    //Model层定义接口,外部只需关心model返回的数据,无需关心内部细节,及是否使用缓存
    interface Model extends IModel {
        Observable<PagingBean<List<Study>>> getStudys(String url);

        Observable<NoBodyEntity> setRead(int rcId);
    }
}
